//通过ES6的导入语法将组件导入进来
import Login from '@/views/Login'
import Home from '@/views/Home'
import NotFound from '@/views/NotFound'
import Register from '@/views/Register'

export default[
    {
        path:'/login',
        component:Login,
    },
    {
        path:'/register',
        component:Register
    },
    {
        path:'/',
        redirect:'/home'
    },
    {
        path:'/home',
        name:'homeName',
        component:Home,
        children:[
            {
                //配置默认二级路由
                path:'',
                redirect:'/home/workplace'
            }
        ]
    },
    {
        path:'*',
        component:NotFound
    },
]